"use strict";
const R = 100;
const angle = 30;
const h = R * Math.cos(angle / 180 * Math.PI);
const r = R * Math.sin(angle / 180 * Math.PI);
const arrHex = ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f"];
const ColorTheme = {
    Neon: 0,
    Light: 1,
    Dark: 2,
    Cold: 3,
    Winter: 4,
    HighContrastRatioLight: 5,
    HighContrastRatioDark: 6,
};
const japanesePhoneticAlphabet = "あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわを";
const canvasWidth = 480;
const canvasHeight = 640;
const mobileCanvasWidth = 540;
const mobileCanvasHeight = 720;
const frontCamera = "user";
const rearCamera = "environment";
const letter = "ABCDEFGHIJKLMNOPQRSTUVQXYZ";
const symbol = letter + "*+■■■■□□＿/＄％＃＆￥";
const DIMENSIONAL = "DIMENSIONAL";
const RIFT = "RIFT";
const TAPTOSTART = "TAP TO START";
const TO_RADIANS = Math.PI / 180;
const Effects = {
    FlashDark: 0,
    FlashLight: 1,
    CharsColorful: 2,
    CharsNormal: 3,
    SingleShape: 4,
    MutipleShape: 5,
    CubeColorful: 6,
    CubeNormal: 7,
    SnowFall: 8,
    StarFall: 9,
};
const MaxEffects = 10;
const sr3 = Math.sqrt(3);
window.onload = function(e) {
    $(function() {
        // 菜单栏的下落和收起
        $("#bt_menu").click(function() {
            let isShow = $("#menu").css("display") == "block";
            $("#menu").stop();
            $("#menu").css("height", isShow ? "100%" : "0%");
            if (!isShow) {
                $("#menu").css("display", "block");
                $("#menu").animate({ height: "100%" }, 100);
            } else {
                $("#menu").animate({ height: "0%" }, 100, "swing", function() {
                    $("#menu").css("display", "none");
                });
            }
        });
        let twitter = $("#twitter");
        let facebook = $("#facebook");
        twitter.click(function() {
            window.open('https://twitter.com/RECNEPS_KIPS');
        });
        facebook.click(function() {
            window.open('https://www.facebook.com/profile.php?id=100021707954561');
        });
        let opacityAnim = function(obj, value) {
            obj.animate({ opacity: value }, 100, "easeOut", function() {
                obj.css("opacity", value);
            });
        }

        twitter.on("mouseenter", function() {
            // twitter.css("opacity", "0.4");
            opacityAnim(twitter, "0.4");
        });
        facebook.on("mouseenter", function() {
            opacityAnim(facebook, "0.4");
        });
        twitter.on("mouseleave", function() {
            opacityAnim(twitter, "1");
        });
        facebook.on("mouseleave", function() {
            opacityAnim(facebook, "1");
        });
    });
}